<?php



/**
 * 系统帮助
 * Enter description here ...
 * @author Admin
 *
 */
class HelpAction extends CommonAction{
	
	
	
	/**
	 * 帮助首页面
	 * Enter description here ...
	 */
    public function index()    {
    	$article = D('Article');    //文章
    	
    	
    	//TODO:帮助中心 文章分类 8
    	
    	$article_categories = D('article_categories');  //文章类别
		$article_categoriesmap['fid'] = array('eq',8);
		$article_categoriesdata = $article_categories->where($article_categoriesmap)->findAll();
		
		foreach ($article_categoriesdata as &$val){
			unset($valmap);
			$valmap['state'] = array('eq',1);
			$valmap['cid'] = array('eq',$val['id']);
			$val['article'] = $article->getdata($valmap);
		}
		
		
		$this->assign('article_categoriesdata',$article_categoriesdata);
        $this->display();
    }
    
    
    
}
?>